<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<head>
	<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
	<title>湖南省自来水公司营销管理信息系统</title>

	<link rel="stylesheet" href="/css/reset.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/text.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/form.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/buttons.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/grid.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/layout.css" type="text/css" media="screen" title="no title" />

	<link rel="stylesheet" href="/css/ui-darkness/jquery-ui-1.8.12.custom.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/plugin/jquery.visualize.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/plugin/facebox.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/plugin/uniform.default.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/plugin/dataTables.css" type="text/css" media="screen" title="no title" />
	<link rel="stylesheet" href="/css/custom.css" type="text/css" media="screen" title="no title">

	<link rel="stylesheet" href="/css/bootstrap.min.css" type="text/css"></link>
	<link type="text/css"rel="stylesheet" href="/js/jquery/bootstrap.min.js"/>
	<script type="text/javascript" src="/js/jquery/jquery.min.js"></script>

	<script type="text/javascript" src="/js/jquery/bootstrap.min.js"></script>
</head>

<body>

<div id="wrapper">



	<div id="header">

		<div class="content_pad">
			<h1><a href="/workspace.html">湖南省自来水公司营销管理信息系统</a></h1>

			<ul id="nav">

				<li class="nav_dropdown nav_icon">
					<a href="javascript:;"><span class="ui-icon ui-icon-wrench"></span>业扩工程</a>

					<div class="nav_menu">
						<ul>
							<li><a href="/page/be__request.html">01 用户申请</a></li>
							<li><a href="/page/be__audit.html">02 初步审核</a></li>
							<li><a href="/page/be__pay.html">03 交施工费</a></li>
							<li><a href="/page/be__billclear.html">04 水费清算</a></li>
							<li><a href="/page/be__contract.html">05 供水协议</a></li>
							<li><a href="/page/be__working.html">06 施工竣工</a></li>
							<li><a href="/page/be__open.html">07 通水停水</a></li>
							<li><a href="/page/be__save.html">08 档案存档</a></li>
							<li><a href="/page/be_order.html">工单管理</a></li>
							<li><a href="/page/be_abort.html">终止工单</a></li>
							<li><a href="/page/be_reportProgress.html">业扩工程进度</a></li>
							<li><a href="/page/be_reportMoney.html">业扩收费报表</a></li>
						</ul>

					</div>
				</li>

				<li class="nav_dropdown nav_icon">
					<a href="javascript:;"><span class="ui-icon ui-icon-person"></span>用户管理</a>

					<div class="nav_menu">
						<ul>
							<li><a href="/page/user_search.html">用户查询</a></li>
							<li><a href="/page/user_add.html">快捷新户</a></li>
							<li><a href="/page/user_changeName.html">快捷过户</a></li>
							<li><a href="/page/user_changeBank.html">快捷代扣</a></li>
							<li><a href="/page/user_changeMeter.html">快捷换表</a></li>
							<li><a href="/page/user_changeFormula.html">快捷重签</a></li>
							<li><a href="/page/user_delete.html">快捷销户</a></li>
							<li><a href="/page/user_reportShortcut.html">快捷操作记录</a></li>
							<li><a href="/page/user_docNum.html">档案号管理</a></li>
							<li><a href="/page/user_sendMsg.html">短信群发</a></li>
						</ul>

					</div>
				</li>

				<li class="nav_dropdown nav_icon">
					<a href="javascript:;"><span class="ui-icon ui-icon-pencil"></span>抄表管理</a>

					<div class="nav_menu">
						<ul>
							<li><a href="./rd_volume.html">表册管理</a></li>
							<li><a href="./RdYearmonth.html">抄表初始化</a></li>
							<li><a href="./rd_task">任务分配</a></li>
							<li><a href="./queryRdRead2">抄表录入</a></li>
							<li><a href="./rd_audit">抄表审核</a></li>
							<li><a href="./queryReportReadingFY">抄表情况查询</a></li>
							<li><a href="./rd_reportVolumeReading">抄表统计报表</a></li>
							<li><a href="./rd_reportZero.html">零吨位用户查询</a></li>
							<li><a href="./rd_reportMaxValue.html">最大码值修正记录</a></li>
							<li><a href="./rd_reportCPreAmount.html">底码修正记录</a></li>
							<li><a href="./rd_reportMeterCheck">水表周检报表</a></li>
						</ul>

					</div>
				</li>

				<li class="nav_dropdown nav_icon">
					<a href="javascript:;"><span class="ui-icon ui-icon-star"></span>收费管理</a>

					<div class="nav_menu">
						<ul>
							<li><a href="./pay_window.html">窗口收费</a></li>
							<li><a href="./pay_batch.html">批量收费</a></li>
							<li><a href="./ShowAll">发票补开/作废</a></li>
							<li><a href="./queryFY">欠费报表</a></li>
							<li><a href="./querymoney">收费情况报表</a></li>
							<li><a href="./queryPyBilldetail">月资金回收情况报表</a></li>
							<li><a href="./pay_reportBalance">用户预收情况报表</a></li>
						</ul>

					</div>
				</li>

				<li class="nav_dropdown nav_icon">
					<a href="javascript:;"><span class="ui-icon ui-icon-script"></span>发票管理</a>

					<div class="nav_menu">
						<ul>
							<li><a href="/page/inv_invoiceManage.html">发票总表</a></li>
							<li><a href="/page/inv_invoiceIn.html">发票入库</a></li>
							<li><a href="/page/inv_invoiceOut.html">发票出库</a></li>
							<li><a href="/page/inv_invoiceArchive.html">发票交票</a></li>
							<li><a href="/page/inv_invoiceReportOut.html">发票出库情况查询</a></li>
							<li><a href="/page/inv_invoiceReportEmp.html">收费人员发票查询</a></li>
							<li><a href="/page/inv_invoiceReportArchive.html">发票交票情况查询</a></li>
							<li><a href="/page/inv_invoiceReportUse.html">发票使用情况查询</a></li>
							<li><a href="/page/inv_invoiceReportMoneySum.html">销账汇总报表</a></li>
							<li><a href="/page/inv_invoiceReportMoneyDetail.html">销账明细报表</a></li>
						</ul>
					</div>
				</li>

				<li class="nav_dropdown nav_icon">
					<a href="javascript:;"><span class="ui-icon ui-icon-gear"></span>系统设置</a>

					<div class="nav_menu">
						<ul>
							<li><a href="/page/sys_area.html">抄表辖区</a></li>
							<li><a href="/page/sys_meterType.html">水表型号</a></li>
							<li><a href="/page/sys_dept.html">部门管理</a></li>
							<li><a href="/page/sys_emp.html">员工管理</a></li>
							<li><a href="/page/sys_menupower.html">菜单权限设置</a></li>
							<li><a href="/page/sys_areapower.html">辖区权限设置</a></li>
							<li><a href="/page/sys_waterType.html">用水类型设定</a></li>
							<li><a href="/page/sys_surcharge.html">附加费设定</a></li>
							<li><a href="/page/sys_flow.html">流程配置</a></li>
						</ul>

					</div>
				</li>

				<li class="nav_current nav_dropdown nav_icon_only">
					<a href="javascript:;">&nbsp;</a>

					<div class="nav_menu">
						<ul>
							<li><a href="/workspace.html">我的工作台</a></li>
							<li><a href="/page/sys_pwd.html">修改密码</a></li>
							<li><a href="/login.html">退出系统</a></li>
						</ul>
					</div> <!-- .menu -->
				</li>
			</ul>
		</div> <!-- .content_pad -->

	</div>

	<!-- #header -->

	<div id="masthead">
		<div>
			<span id="pagetitle"><a href="javascript:;">表册管理</a></span>
			<span id="welcome_span">欢迎回来，马云</span>
		</div>
	</div> <!-- #masthead -->

	<div id="content" class="xgrid">

		<div class="x12">

			<div id="facebox_delete" style="display: none">
				<div style="height:80px;text-align:center;padding-top:50px;">
					确认删除吗？
				</div>

				<div class="dialogbutton center">
					<a class="btn" href="javascript:closeDialog();" style="width:60px;">是</a>
					<a class="btn btn-grey" href="javascript:closeDialog();" style="width:60px;">否</a>
				</div>
			</div>

			<div id="facebox_setVolume" style="display: none">
				<div id="facebox_setVolume_message" style="height:80px;text-align:center;padding-top:50px;">
					确认移动到此表册吗？
				</div>

				<div class="dialogbutton center">
					<a class="btn" href="javascript:closeDialog();" style="width:60px;">是</a>
					<a class="btn btn-grey" href="javascript:closeDialog();" style="width:60px;">否</a>
				</div>
			</div>

			<table id="parent_table">
				<tr>
					<td width="30%">
						<h2>表册管理</h2>

						<p>
							<br/>
						<div style="float:left;height:42px;">
							<button class="btn-icon btn-plus" onClick="location='/rd_volume_add.html';"><span></span>添加表册</button>
						</div>
						</p>

						<table class="data display">
							<thead>
							<tr>
								<th>未分配表册的用户</th>
								<th></th>
							</tr>
							</thead>
							<tbody>
							<tr class="odd gradeX">
								<td><a href="/rd_volume.html">未分配表册的用户</a></td>
								<td class="right">&nbsp;</td>
							</tr>
							</tbody>
						</table>

						<table class="data display" th:each="a,i:${areas}">
							<thead>
							<tr>
								<th th:text="*{a.AreaName}"></th>
								<th></th>
							</tr>
							</thead>
							<tbody>
							<tr class="odd gradeX" th:each="v:*{a.rdVolumes}">
								<td><a th:href="|/queryById/*{v.ID}|" th:text="*{v.volumeName}"></a></td>
								<td class="right">
									<a th:href="|/updateShow/*{v.ID}|">[修改]</a>
									<a th:href="|javascript:del(${v.ID})|"  rel="facebox">[删除]</a>
								</td>
							</tr>

							</tbody>
						</table>


					</td>
					<td width="1%">&nbsp;</td>
					<td width="69%">
						<h2>未分配表册的用户</h2>

						<div style="float:right;">
							分配至
							<select id="select_area" class="medium" onChange="set(this);">
								<option></option>
								<option th:value="0">未分配</option>
								<optgroup th:each="a,i:${areas}" th:label="*{a.AreaName}">
									<option th:each="v:*{a.rdVolumes}" th:value="*{v.ID}"> [[*{v.volumeName}]] </option>
								</optgroup>

							</select>
						</div>
						<form name="f1" action="updateVid">
						<table class="table table-hover">
							<thead>
							<tr>
								<th>&nbsp;</th>
								<th>排序号</th>
								<th>用户编码</th>
								<th>表身码</th>
								<th>用户姓名</th>
								<th>地址</th>
							</tr>
							</thead>
							<tbody>
							<tr class="odd gradeX" th:each="u,i:${list}">
								<td><input type="checkbox" name="cbox" th:value="*{u.UserNo}"/></td>
								<td>未分配</td>
								<td th:text="*{u.UserNo}"></td>
								<td th:text="*{u.MeterName}"></td>
								<td th:text="*{u.UserName}"></td>
								<td th:text="*{u.Address}"></td>
							</tr>

							</tbody>
						</table>
							<input type="hidden" id="hi" name="hi">
						</form>
                  <input type="hidden" id="pageCount" th:value="${#httpServletRequest.getAttribute('pageCount')}"/>
				  <input type="hidden" id="currentPage" th:value="${#httpServletRequest.getParameter('currentPage')}"/>
						<ul class="pagination" id="pagination1"></ul>
						<ul id="p1" class="button"></ul>
					</td>
				</tr>
			</table>

		</div> <!-- .x12 -->

	</div> <!-- #content -->

	<div id="footer">
		<div class="content_pad">
			<p>&copy; 2013-11 版权所有 <a href="#">湖南省自来水公司</a>.   技术支持 <a href="#">职业教育</a>.</p>
		</div> <!-- .content_pad -->
	</div> <!-- #footer -->

</div> <!-- #wrapper -->

<script src="/js/jquery/jquery.min.js"></script>
<script src="/js/jquery/jquery-ui-1.8.12.custom.min.js"></script>
<script src="/js/misc/excanvas.min.js"></script>
<script src="/js/jquery/facebox.js"></script>
<script src="/js/jquery/jquery.visualize.js"></script>
<script src="/js/jquery/jquery.dataTables.min.js"></script>
<script src="/js/jquery/jquery.tablesorter.min.js"></script>
<script src="/js/jquery/jquery.uniform.min.js"></script>
<script src="/js/jquery/jquery.placeholder.min.js"></script>
<script src="js/jqPaginator.js"></script>
<script src="/js/widgets.js"></script>
<script src="/js/dashboard.js"></script>


<script type="text/javascript">
$(document).ready(function(){
    var pageNum=5
	var currentPage=$("#currentPage").attr("value")


	if(currentPage==""||currentPage==null){

        currentPage=1
	}



    var pageCount=$("#pageCount").attr("value")

	var   totalPages=0
  var  visiblePages=10

if(pageCount<=pageNum){

    visiblePages=1
    totalPages=1
}else{

    totalPages =Math.ceil(pageCount/pageNum)
    totalPages<visiblePages?visiblePages=totalPages:null
}



    $.jqPaginator('#pagination1', {
        totalPages: totalPages,
        visiblePages: visiblePages,
        currentPage: eval(currentPage),
        first:'<li class="first"><a href="javascript:void(0);">First</a></li>',
        prev: '<li class="prev"><a href="javascript:void(0);">Previous</a></li>',
        next: '<li class="next"><a href="javascript:void(0);">Next</a></li>',
        last: '<li class="last"><a href="javascript:void(0);">Last</a></li>',
        page: '<li class="page"><a href="javascript:void(0);">{{page}}</a></li>',
        onPageChange: function (num, type) {

if(type=="change"){

    window.location.href="/rd_volume.html?currentPage="+num

}

        }
    });




})

    </script>



<script>
	function set(s) {
	    var aaa=false;
	    var cbox=document.getElementsByName("cbox");
	    for (var a=0;a<cbox.length;a++){
			if(cbox[a].checked==true){
				aaa=true;

			}

		}

	    if(aaa==true){
            if(confirm("确定移动到该表册吗？")){
                document.getElementById("hi").value=s.value;
                f1.submit();
            }else {
                return;
            }
        }else{
	        alert("请先选中再提交");
	        return;
		}


		
    }
    
    
    function del(id) {
	    if(confirm("是否删除此表册？")) {
            location = "/delVolumeById/"+ id
        }else {
	        return
		}
    }





</script>



</body>

</html>